﻿CREATE TABLE [dbo].[order_product_details] (
    [ID]        INT             IDENTITY (1, 1) NOT NULL,
    [OID]       INT             NOT NULL,
    [ProductID] INT             NOT NULL,
    [Quantity]  DECIMAL (18, 5) NOT NULL,
    [CostMoney] DECIMAL (10, 5) NOT NULL,
    [Retention] VARCHAR (10)    NULL,
    CONSTRAINT [PK__order_pr__3214EC271A14E395] PRIMARY KEY CLUSTERED ([ID] ASC),
    CONSTRAINT [FK_order_product_details_order_product] FOREIGN KEY ([OID]) REFERENCES [dbo].[order_product] ([ID]) ON DELETE CASCADE,
    CONSTRAINT [FK_order_product_details_products] FOREIGN KEY ([ProductID]) REFERENCES [dbo].[products] ([ID])
);



